export function getExamStatusHtml(status) {
	switch (status) {
		case "00":
            return {
                text:'取消检查',
                color:'#b5a083'
            };
			break;
		case "10":
            return {
                text:'预约确认',
                color:'#999999'
            };
			break;
		case "20":
            return {
                text:'已经报到',
                color:'#666666'
            };
			break;
		case "30":
            return {
                text:'登记信息',
                color:'#444444'
            };
			break;
		case "40":
            return {
                text:'叫号完成',
                color:'#afddf7'
            };
			break;
		case "50":
            return {
                text:'正在检查',
                color:'#46d0e2'
            };
			break;
		case "60":
            return {
                text:'收到影像',
                color:'#27455d'
            };
			break;
		case "65":
            return {
                text:'审核退回',
                color:'#ff5722'
            };
			break;
		case "70":
            return {
                text:'初步报告',
                color:'#73e477'
            };
			break;
		case "80":
            return {
                text:'确认报告',
                color:'#32bd37'
            };
			break;
		case "90":
            return {
                text:'发布报告',
                color:'#09650c'
            };
			break;
		case "95":
            return {
                text:'报告打印',
                color:'#033c05'
            };
			break;
		default:
            return {
                text:'无效状态',
                color:'#dcb173'
            };
	}
}

export function ConvertShortDT(str) {
	str = str.substring(str.indexOf("-") + 1, str.lastIndexOf(":"))
	return `${str}`;
}
//日期函数
export function format(timestamp) {
    var time = new Date(timestamp);
    var month = (time.getMonth() + 1) > 9 && (time.getMonth() + 1) || ('0' + (time.getMonth() + 1))
    var date = time.getDate() > 9 && time.getDate() || ('0' + time.getDate())
    var hour = time.getHours() > 9 && time.getHours() || ('0' + time.getHours())
    var minute = time.getMinutes() > 9 && time.getMinutes() || ('0' + time.getMinutes())
    return `${month}-${date} ${hour}:${minute}`;
}